package net.xinqushi.design.COR.impl;

import net.xinqushi.design.COR.ConsumeHandler;

public class ProjectHandler extends ConsumeHandler {
    @Override
    public void doHandler(String user, double free) {
        //费用500以下项目经理可以批准
        if(free < 500){
            if(user.equals("xjie")){
                System.out.println("Project给予报销:" + free);
            }else{
                System.out.println("Project got out");
            }
            return;
        }

        //500以上找上面的人
        if(getNextHandler() != null)
            getNextHandler().doHandler(user,free);

    }
}
